AO3-7410 Fix the inconsistency in the site name on the page title for works and series#5766
AO3-7410 Fix the inconsistency in the site name on the page title for works and series#5766CelineB-sudo wants to merge 5 commits into
Conversation
marcus8448
left a comment
There was a problem hiding this comment.
Thanks for working on this!
| end | ||
|
|
||
| page_title += " [#{ArchiveConfig.APP_NAME}]" unless options[:omit_archive_name] | ||
| page_title += " | #{ArchiveConfig.APP_NAME}" unless options[:omit_archive_name] |
There was a problem hiding this comment.
I think it would be a bit nicer to stop appending the app name altogether in this function, and instead update all of its uses to set @page_subtitle instead of @page_title.
There was a problem hiding this comment.
Good call 👍 More files have changed, mainly because I renamed 2 functions for clarity.
Rspec tests have been added to check how browser_page_title sets the app name in the title.
… works and series
- Remove APP_NAME appending from get_page_title - Update works_controller, chapters_controller, series_controller to use @page_subtitle - Remove obsolete omit_archive_name option from comments_controller - Rename get_page_title to get_page_subtitle for clarity - Rename work_page_title to work_page_subtitle for clarity - Updated tests and added tests for browser_page_title
| And I should not see "pinchhitter" | ||
| When I follow "Fulfilling Story 1" | ||
| Then I should see the page title "Fulfilling Story 1 - Anonymous - Stargate Atlantis [Example Archive]" | ||
| Then I should see the page title "Fulfilling Story 1 - Anonymous - Stargate Atlantis | Example Archive" |
There was a problem hiding this comment.
One extra (optional) note: Since this test is being updated, could you add a And the app name is "Example Archive" to the list of Given steps? This prevents the test from failing when a custom app name is set in the config.
Pull Request Checklist
as the first thing in your pull request title (e.g.
AO3-1234 Fix thing)until they are reviewed and merged before creating new pull requests.
Issue
https://otwarchive.atlassian.net/browse/AO3-7410
Purpose
What does this PR do?
It resolves the inconsistency in the page titles for works and series. The browser page title had the site name formatted as "[App Name]," but every other page uses the format "| App Name."
Now, all pages use the format “| App Name”.
The tests have been updated to reflect the changes.
Credit
What name and pronouns should we use to credit you in the Archive of Our Own's Release Notes?
Céline Bertaud (she/her)